package com.wing.wcabinet.model.request;

import com.baomidou.mybatisplus.annotation.TableField;
import com.wing.cabinet.model.request.StorageInventoryInoutDetailForm;
import com.wing.wcabinet.model.entity.WcabCellAllocationDetail;
import com.wing.wcabinet.model.entity.WcabCellInventoryInout;
import com.wing.wcabinet.model.entity.WcabCellInventorySpace;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import java.time.LocalDateTime;
import com.wing.wcabinet.model.entity.WcabCellInventoryInoutDetail;
import java.time.LocalDateTime;
import org.springframework.format.annotation.DateTimeFormat;
import java.math.BigDecimal;
import java.util.List;

/**
 * 售刀柜上货(上货主表无展示)/领取明细Form
 *
 * @author
 */
@Data
@NoArgsConstructor
@Accessors(chain = true)
public class WcabCellInventoryInoutDetailForm {

    /**
     * ID
     */
    private Long id;

    /**
     * 创建者
     */
    private Long creator;

    /**
     * 修改者
     */
    private Long modifier;

    /**
     * 创建人
     */
    private String creatorName;

    /**
     * 修改人
     */
    private String modifierName;

    /**
     * 上货/领取id
     */
    private Long inoutId;

    /**
     * 柜子id
     */
    private Long cabId;

    /**
     * sku id
     */
    private Long skuId;

    /**
     * 数量
     */
    private Integer quantity;

    /**
     * 重量
     */
    private BigDecimal weight;

    /**
     * 货道id
     */
    private Long spaceId;


    /**
     * sku code
     */
    private String skuCode;

    /**
     * 柜子编码
     */
    private String cabCode;

    /**
     * 当前库存
     */
    private Integer quantityCurrent;

    /**
     * 变动后库存
     */
    private Integer quantityAfter;

    /**
     * 货道/货位id
     */
    private String spaceCode;

    /**
     * 是否已同步：no(0,未同步);yes(1,已同步);
     */
    private Integer isSyns;

    /**
    * 同步时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime synsTime;

    /**
     * enterpriseId
     */
    private Long enterpriseId;

    /**
     * enterpriseCode
     */
    private String enterpriseCode;


    public interface Add{}

    public interface Update{}

    private BigDecimal weightCurrent;

    private BigDecimal weightAfter;

    /**
     * operationTypeChecked
     */
    private Integer operationTypeChecked;

    /**
     * quantityAfterChecked
     */
    private Integer quantityAfterChecked;

    /**
     * repairPrice
     */
    private BigDecimal repairPrice;

    /**
     * 签收数量
     */
    private Integer quantitySign;


    /**
     * 操作类型描述
     */
    @TableField(exist = false)
    private String operationTypeDesc;

    public String getOperationTypeDesc() {
        return operationType == null ? null : operationType.getDesc();
    }


    /**
     * 业务类型描述
     */
    @TableField(exist = false)
    private String businessTypeDesc;

    public String getBusinessTypeDesc() {
        return businessType == null ? null : businessType.getDesc();
    }

    /**
     * quantityChecked
     */
    private Integer quantityChecked;




    private String cabCodeTarget;

    private Long cabIdTarget;

    private String spaceCodeTarget;

    private Long spaceIdTarget;

    private String cabCodeSource;

    private Long cabIdSource;

    private String spaceCodeSource;

    private Long spaceIdSource;

    /**
     * 操作类型
     */
    private WcabCellInventoryInoutDetail.OperationType operationType;
    /**
     * 业务类型
     */
    private WcabCellInventoryInoutDetail.BusinessType businessType;


    private String targetCabCode;

    private String targetSpaceCode;


    private Boolean isCorrect;

    private Boolean businessTypeCorrect;

    private Boolean skuCorrect;

    private String checkCabCode;

    private String checkSpaceCode;

    private String remark;

    private List<WcabCellInventoryInoutDetailForm> detailList;

    private WcabCellInventoryInoutDetail.BusinessTypeChecked businessTypeChecked;


    private Boolean flag;

    private Long categoryId;


    private BigDecimal weightChecked;


    private Long workOrderId;

    private String deviceCode;

    private Long requestProductId;

    private BigDecimal weightPre;

    private Integer quantityPre;


    private Boolean weightCorrect;

    private Boolean quantityCorrect;

    private String skuCodeChecked;

}
